package com.zzjson.design.decorator.battercake.v2;

/**
 * <p>****************************************************************************</p>
 * <p><b>Copyright © 2010-2019 shuncom team All Rights Reserved<b></p>
 * <ul style="margin:15px;">
 * <li>Description : cn.zzjson.design.decorator.battercake.v2</li>
 * <li>Version     : 1.0.0</li>
 * <li>Creation    : 2019年04月02日</li>
 * <li>@author     : zzy0_0</li>
 * </ul>
 * <p>****************************************************************************</p>
 */
public class App {
    public static void main(String[] args) {
        Battercake battercake;
        battercake = new BaseBattercake();

        battercake = new EggDecorator(battercake);
        System.out.println(battercake.getMsg());
        System.out.println(battercake.getPrice());

        battercake = new EggDecorator(battercake);
        System.out.println(battercake.getMsg());
        System.out.println(battercake.getPrice());

        battercake = new SausageDecorator(battercake);
        System.out.println(battercake.getMsg());
        System.out.println(battercake.getPrice());
    }

}